﻿<%@ Page Language="C#" MasterPageFile="MasterPage.Master" AutoEventWireup="true"
    CodeBehind="UserProfile.aspx.cs" Inherits="Billing.UserProfile" %>
<%@ Register Src="~/Controls/Admin/ucUserProfile.ascx" TagName="ucUserProfile" TagPrefix="uc1" %>
<%@ Register src="~/Controls/ucPageTitle.ascx" tagname="ucPageTitle" tagprefix="uc2" %>
<%@ Register src="~/Controls/ucInProgress.ascx" tagname="ucInProgress" tagprefix="uc3" %>
<%@ Register src="~/Controls/ucSearch.ascx" tagname="ucSearch" tagprefix="uc4" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <link type="text/css" href="Css/jquery-ui-1.8.4.custom.css" rel="stylesheet" />
    <script type="text/javascript">
        $(function () {
            // Dialog 
            $('#dialogSave').dialog({
                autoOpen: false,
                width: 600,
                modal: true
            });
            $('#dialog').parent().appendTo($("form"));
            $('#dialogUpdate').dialog({
                autoOpen: false,
                width: 600,
                modal: true
            });
            $('#dialog').parent().appendTo($("form"));
        });

        
        
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
 <uc2:ucPageTitle ID="ucPageTitle1" runat="server" />
      <asp:UpdatePanel ID="UpdatePanel5" runat="server">
    <ContentTemplate>
         <uc4:ucSearch ID="ucSearch" runat="server" />
    </ContentTemplate>
    </asp:UpdatePanel>
    <br />
    <asp:UpdatePanel ID="UpdatePanel2" runat="server">
        <ContentTemplate><div class="gridDetail">
            <asp:GridView ID="gvCustomView" runat="server" CellPadding="0" CellSpacing="1" CssClass="GridViewStyle"
                GridLines="None" AutoGenerateColumns="False" 
                OnRowCommand="gvCustomView_RowCommand" AllowPaging="True" 
                AllowSorting="True" onpageindexchanging="gvCustomView_PageIndexChanging" 
                PageSize="50" EnableModelValidation="True" 
                EnableSortingAndPagingCallbacks="True" onsorting="gvCustomView_Sorting" PagerSettings-Mode="NumericFirstLast">
                <RowStyle CssClass="GridViewRowStyle" />
                <Columns>
                    <asp:TemplateField HeaderStyle-HorizontalAlign="Center" HeaderText="No">
                        <ItemTemplate>
                            <asp:Label ID="xCol01" runat="server" Text='<%#Container.DataItemIndex+1  %>'></asp:Label>
                        </ItemTemplate>
                        <HeaderStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderStyle-HorizontalAlign="Center" HeaderText="Login ID" 
                        SortExpression="LoginId">
                        <ItemTemplate>
                            <asp:LinkButton runat="server" ID="linkBtnEdit" CommandArgument='<%#Microsoft.Security.Application.Encoder.HtmlEncode(Convert.ToString(Eval("UserID")))%>'
                                CommandName="EditData" Text='<%#Microsoft.Security.Application.Encoder.HtmlEncode(Convert.ToString(Eval("LoginId")))%>'></asp:LinkButton>
                        </ItemTemplate>
                        <HeaderStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderStyle-HorizontalAlign="Center" 
                        HeaderText="Name" SortExpression="Name0">
                        <ItemTemplate>
                            <asp:Label ID="xCol02" runat="server" Text='<%#Microsoft.Security.Application.Encoder.HtmlEncode(Convert.ToString(Eval("Name0")))%>'></asp:Label>
                        </ItemTemplate>
                        <HeaderStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderStyle-HorizontalAlign="Center" 
                        HeaderText="Email" SortExpression="Email">
                        <ItemTemplate>
                            <asp:Label ID="xCol03" runat="server" Text='<%#Microsoft.Security.Application.Encoder.HtmlEncode(Convert.ToString(Eval("Email")))%>'></asp:Label>
                        </ItemTemplate>
                        <HeaderStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderStyle-HorizontalAlign="Center" 
                        HeaderText="Office Number" SortExpression="PrimaryPhone">
                        <ItemTemplate>
                            <asp:Label ID="xCol04" runat="server" Text='<%#Microsoft.Security.Application.Encoder.HtmlEncode(Convert.ToString(Eval("PrimaryPhone")))%>'></asp:Label>
                        </ItemTemplate>
                        <HeaderStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderStyle-HorizontalAlign="Center" 
                        HeaderText="Mobile Number" SortExpression="SecondaryPhone">
                        <ItemTemplate>
                            <asp:Label ID="xCol05" runat="server" Text='<%#Microsoft.Security.Application.Encoder.HtmlEncode(Convert.ToString(Eval("SecondaryPhone")))%>'></asp:Label>
                        </ItemTemplate>
                        <HeaderStyle HorizontalAlign="Center" />
                    </asp:TemplateField>
                    <asp:TemplateField HeaderStyle-HorizontalAlign="Center" HeaderText="Member" 
                        SortExpression="GroupName">
                        <ItemTemplate>
                            <asp:Label ID="xCol06" runat="server" Text='<%#Microsoft.Security.Application.Encoder.HtmlEncode(Convert.ToString(Eval("GroupName")))%>'></asp:Label>
                        </ItemTemplate>                        
                        <HeaderStyle HorizontalAlign="Center" />                        
                    </asp:TemplateField>
                    <asp:TemplateField HeaderStyle-HorizontalAlign="Center" HeaderText="Active" 
                        SortExpression="UserStatus">
                        <ItemTemplate>
                            <asp:Label ID="xCol07" runat="server" Text='<%#Microsoft.Security.Application.Encoder.HtmlEncode(Convert.ToString(Eval("UserStatus")))%>'></asp:Label>
                        </ItemTemplate>                        
                        <HeaderStyle HorizontalAlign="Center" />                        
                    </asp:TemplateField>
                </Columns>
                <HeaderStyle CssClass="GridViewHeaderStyle" />
                <AlternatingRowStyle CssClass="GridViewAlternatingRowStyle" />
            </asp:GridView></div>
        </ContentTemplate>
    </asp:UpdatePanel>
    <br />
    <asp:UpdatePanel ID="UpdatePanel3" runat="server">
        <ContentTemplate>
            <asp:Button ID="btnAdd" runat="server" Text="Add" CausesValidation="false" CssClass="ui-state-default ui-corner-all"
                OnClick="btnAdd_Click" />
        </ContentTemplate>
    </asp:UpdatePanel>
    <asp:UpdateProgress ID="UpdateProgress1" runat="server" AssociatedUpdatePanelID="UpdatePanel3">
    <ProgressTemplate>
        <uc3:ucInProgress ID="ucInProgress" runat="server" />        
    </ProgressTemplate>
    </asp:UpdateProgress>
    <div id="dialogSave" title="Add User Menu" style="display: none">
        <div id="dialogSaveEffect">
            <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                <ContentTemplate>
                    <uc1:ucUserProfile ID="ucUserProfile1" runat="server" />
                </ContentTemplate>
            </asp:UpdatePanel>
        </div>
    </div>
    <div id="dialogUpdate" title="Update User Menu" style="display: none">
        <div id="dialogUpdateEffect">
            <asp:UpdatePanel ID="UpdatePanel4" runat="server">
                <ContentTemplate>
                    <uc1:ucUserProfile ID="ucUserProfile2" runat="server" />
                </ContentTemplate>
            </asp:UpdatePanel>
        </div>
    </div>
    <br />
    <br />
</asp:Content>
